Copyright ã1995 by NeXT Computer, Inc.  All Rights Reserved.

NS_DEV_DOCFOR:objc_protocol:NXSelectText;,NXSelectText

Adopted By:	Text

Declared In:	appkit/NXSpellChecker.h

Protocol Description

This protocol must be implemented by an object whose text is to be checked, so that it can respond to messages from an NXSpellChecker.

Instance Methods

NS_DEV_DOCFOR:objc_method:[NXSelectText-makeSelectionVisible];,makeSelectionVisible

- (void)makeSelectionVisible

Scrolls the view that contains the selection so that the selection is visible.

NS_DEV_DOCFOR:objc_method:[NXSelectText-readCharactersFromSelection:count:];,readCharactersFromSelection:count:

- (int)readCharactersFromSelection:(char *)buffer count:(int)count

Reads a substring from the selected portion of the text stream.  The argument count is the desired number of characters to read.  The argument buffer is a pointer to the start of the resulting character string.  Returns the number of characters actually read (which may be smaller than the number requested if the selected portion of the text stream is not that long).

NS_DEV_DOCFOR:objc_method:[NXSelectText-selectCharactersFrom:to:];,selectCharactersFrom:to:

- (void)selectCharactersFrom:(int)start to:(int)end

Selects (that is, highlights in the document's display) the specified block of characters.  The arguments start and end are the number of characters from the start of the text stream (which may differ from the number of bytes if the text stream includes multibyte characters).

NS_DEV_DOCFOR:objc_method:[NXSelectText-selectionCharacterCount];,selectionCharacterCount

- (int)selectionCharacterCount

Returns the length (that is, the number of characters) of the portion of the text stream that is currently selected.